package com.runda.controller;

import javax.annotation.Resource;

import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.bind.annotation.RestController;

import com.runda.service.ICountService;
import com.runda.util.DataEntity;

import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;

@Api(tags="CountApi", description="考试中心统计")
@RestController
@RequestMapping(path="count", produces="application/json;charset=utf-8")
public class CountController {

	@Resource
	private ICountService countservice;
	
	@ApiOperation(value="获取首页统计数据", notes="获取首页统计数据")
	@RequestMapping(value = "homepageCount", method = RequestMethod.GET)
	@ResponseBody
	public DataEntity homepageCount() {
		return DataEntity.getInstance(countservice.homepageCount());
	}

}
